﻿@using Smartstore.Web.Models.Catalog;

@model ProductSummaryModel

@{
    var isGrid = Model.ViewMode == ProductSummaryViewMode.Grid;
}

<div class="artlist-action artlist-action--viewmode">
    <div class="btn-group btn-group-toggle" data-toggle="buttons">
        <a href='@Display.ModifyQueryString(null, "?v=grid")'
            class="btn btn-secondary btn-icon btn-artlist-action tooltip-toggle" 
            attr-class='(isGrid, "active")' data-toggle="tooltip" 
            rel="nofollow" 
            title="@T("Products.SwitchToGrid")">
            <input type="radio" name="artlist-viewmode" id="artlist-viewmode-grid" attr-checked='(isGrid, "checked")' />
            <i class="fa fa-grip"></i>
        </a>
        <a href='@Display.ModifyQueryString(null, "?v=list")'
            class="btn btn-secondary btn-icon btn-artlist-action tooltip-toggle"
            attr-class='(!isGrid, "active")' 
            data-toggle="tooltip"
            rel="nofollow" 
            title="@T("Products.SwitchToList")">
            <input type="radio" name="artlist-viewmode" id="artlist-viewmode-list" attr-checked='(!isGrid, "checked")' />
            <i class="fa fa-list"></i>
        </a>
    </div>
</div>